<%@ page import="com.chinaunicom.research.bigdatalabs.util.Tools" %>
<%@ page import="com.chinaunicom.research.bigdatalabs.util.Pair" %>
<%@ page import="java.util.Arrays" %>
<%--
  Created by IntelliJ IDEA.
  User: zhangxr103
  Date: 2014/10/21
  Time: 14:01
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" pageEncoding="utf-8" %>

<%
    String phone = null;
    Object number = request.getParameter("number");
    if (number != null && !number.toString().isEmpty() || request.getSession().getAttribute("number") != null) {
        if (number != null && !number.toString().isEmpty()) {
            request.getSession().setAttribute("number", number);
        }
        phone = request.getSession().getAttribute("number").toString();
    } else {
        response.sendRedirect(request.getContextPath()+"/pages/startpage.jsp");
    }


    Pair<String[],int[]> pair=Tools.LoadData(Tools.class.getResource("/CB.txt_score.csv").getPath(),900,50);

    String value_x =Tools.Array2String(pair.getKey(), 5, pair.getKey().length);
    String value_y = Tools.Array2String(pair.getValue(), 5, pair.getValue().length);
%>

<html>
<head>
    <title>基本信息</title>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">
    <script src="<%=request.getContextPath()%>/js/jquery/jquery-2.0.0.min.js" type="text/javascript"></script>
    <script src="<%=request.getContextPath()%>/js/bootstrap/bootstrap.min.js" type="text/javascript"></script>
    <script src="<%=request.getContextPath()%>/js/highcharts/highcharts.js" type="text/javascript"></script>
    <link href="<%=request.getContextPath()%>/css/bootstrap-combined.min.css" rel="stylesheet" media="screen">
    <script type="text/javascript" src="<%=request.getContextPath()%>/js/highcharts/funnel.js"></script>


    <script type="text/javascript" src="<%=request.getContextPath()%>/js/highcharts/exporting.js"></script>
    <script type="text/javascript" src="<%=request.getContextPath()%>/js/highcharts/highcharts-more.js"></script>
    <script>
        $(function () {
            $('#container').highcharts({
                chart: {
                    type: 'column',
                    margin: [ 50, 50, 100, 80]
                },
                title: {
                    text: 'Worlds largest cities per 2008'
                },
                xAxis: {
                    categories: [
                        <%=value_x.replaceAll("\\[","'").replaceAll("\\]","'").replaceAll(",","','")%>
                    ],
                    labels: {
                        rotation: -45,
                        align: 'right',
                        style: {
                            fontSize: '13px',
                            fontFamily: 'Verdana, sans-serif'
                        }
                    }
                },
                yAxis: {
                    min: 0,
                    title: {
                        text: 'Population (millions)'
                    }
                },
                legend: {
                    enabled: false
                },
                tooltip: {
                    pointFormat: 'Population in 2008: <b>{point.y:.1f} millions</b>'
                },
                series: [{
                    name: 'Population',
                    data: <%=value_y%>,
                    dataLabels: {
                        enabled: true,
                        rotation: -90,
                        color: '#FFFFFF',
                        align: 'right',
                        x: 4,
                        y: 10,
                        style: {
                            fontSize: '13px',
                            fontFamily: 'Verdana, sans-serif',
                            textShadow: '0 0 3px black'
                        }
                    }
                }]
            });
        });
    </script>

</head>
<body>
<div class="container-fluid">
    <div class="row-fluid">
        <div class="span12" >
            <img src="<%=request.getContextPath()%>/img/header.jpg" style="width: 100%;height: 25%;">
        </div>
    </div>
    <div class="row-fluid">
        <div class="span12">
            <ul class="nav nav-tabs">
                <li class="active">
                    <a href="<%=request.getContextPath()%>/pages/privacy.jsp">基本信息</a>
                </li>
                <%--<li >--%>
                    <%--<a href="<%=request.getContextPath()%>/pages/rank.jsp">信用排名</a>--%>
                <%--</li>--%>
                <li >
                    <a href="<%=request.getContextPath()%>/pages/finance.jsp">消费走势</a>
                </li>
                <li>
                    <a href="<%=request.getContextPath()%>/pages/location.jsp">位置跟踪</a>
                </li>
                <li>
                    <a href="<%=request.getContextPath()%>/pages/socialnetwork.jsp">社交网络</a>
                </li>

                <li class="dropdown pull-right">
                    <a href="#" data-toggle="dropdown" class="dropdown-toggle"><%=phone%><strong class="caret"></strong></a>
                    <ul class="dropdown-menu">
                        <li>
                            <a href="#"></a>
                        </li>
                        <li>
                            <a href="#">设置栏目</a>
                        </li>
                        <li>
                            <a href="#">更多设置</a>
                        </li>
                        <li class="divider">
                        </li>
                        <li>
                            <a href="<%=request.getContextPath()%>/pages/startpage.jsp">退出</a>
                        </li>
                    </ul>
                </li>
            </ul>
        </div>
    </div>
    <div class="row-fluid">
        <div class="container-fluid">
            <div class="row-fluid">
                <div class="span12">
                </div>
            </div>
            <div class="row-fluid text-center">
                <div class="span12">
                    <div class="row-fluid">
                        <div class="span3 text-right" style="top:50%">
                            <img alt="163x148" src="<%=request.getContextPath()%>/img/male.png" />
                        </div>
                        <div class="span3 text-center" style="top:50%">
                            <table  style="width:200px;height:150px">
                                <tbody>
                                <tr>
                                    <td>
                                        姓名
                                    </td>
                                    <td>
                                        XXX
                                    </td>
                                </tr>
                                <tr class="error">
                                    <td>
                                        年龄
                                    </td>
                                    <td>
                                        30
                                    </td>
                                </tr>
                                <tr class="warning">
                                    <td>
                                        城市
                                    </td>
                                    <td>
                                        北京
                                    </td>
                                </tr>
                                <tr class="warning">
                                    <td>
                                       套餐
                                    </td>
                                    <td>
                                        96A
                                    </td>
                                </tr>
                                <tr class="warning">
                                    <td>
                                        得分
                                    </td>
                                    <td>
                                        160
                                    </td>
                                </tr>
                                </tbody>
                            </table>
                        </div>
                        <div class="span6">
                            <div id="container" style="width:100%;height:400px"></div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

</div>
<div id="bottom" style="clear:both;bottom:0;text-align:center;vertical-align:middle;width:100%;border:0px;"><span>版权所有@中国联合网络通信有限公司研究院</span></div>
</body>
</html>
